package rtp.model.manager;

import java.util.ArrayList;
import rtp.model.dao.*;
import rtp.model.*;

public class TarefaManager {

	private ITarefaDAO daoTarefa;
	
	public TarefaManager(ITarefaDAO dao)
	{
		daoTarefa = dao;
	}
	
	public void criarTarefa(Tarefa task) 
	{
		task.setStatus("A");
		task.setDtConclusao("");
		task.setSolucao("");
		
		daoTarefa.criarTarefa(task);

	}
	
	public void concluirTarefa(Tarefa task)
	{
		daoTarefa.concluirTarefa(task);
	}
	
	public ArrayList<Tarefa> listarTarefas(String status)
	{
		return daoTarefa.listarTarefas(status);
	}
	
	public Tarefa retornarTarefa(String id)
	{
		return daoTarefa.retornarTarefa(id);
	}
	
}
